import request from '@/utils/request';
import { IotProductForm, IotProductVO } from './types';
import { AxiosPromise } from 'axios';


// 获得产品物模型
export const getProductThingModel = (productId: string | number): AxiosPromise<IotProductVO> => {
  return request({
    url: '/system/iot/thing-model/' + productId,
    method: 'get'
  });
};

// 更新产品物模型
export const updateProductThingModel = (data: IotProductForm) => {
  return request({
    url: '/system/iot/thing-model',
    method: 'put',
    data: data
  });
};


